home *** CD-ROM | disk | FTP | other *** search
- onClipEvent(enterFrame){
- if(this._x < _root._xmouse && _root._xmouse - this._x < 70)
- {
- xmove = true;
- }
- if(this._x > _root._xmouse && _root._xmouse - this._x > -70)
- {
- xmove = true;
- }
- if(this._y - _root._ymouse > -100 && this._y - _root._ymouse < 0)
- {
- ymove = true;
- }
- if(yspeed < _root.gravity && this._y <= base)
- {
- yspeed += 0.5;
- _root.score += 1;
- }
- if(this._y + yspeed <= base)
- {
- this._y += yspeed;
- }
- else
- {
- this._y = base;
- yspeed = - yspeed / bounce;
- _root.score = 0;
- }
- if(_root.increasethrust == true)
- {
- if(xmove == true && ymove == true)
- {
- xspeed -= (_root._xmouse - this._x) / weight;
- yspeed -= (100 - (this._y - _root._ymouse)) / weight;
- }
- }
- if(this._y > base)
- {
- this._y = base;
- }
- if(this._x + xspeed < rw)
- {
- this._x += xspeed;
- }
- else
- {
- this._x = rw;
- xspeed = - xspeed / bounce;
- _root.score = 0;
- }
- if(this._x + xspeed > lw)
- {
- this._x += xspeed;
- }
- else
- {
- this._x = lw;
- xspeed = - xspeed / bounce;
- _root.score = 0;
- }
- this._rotation += xspeed * 3;
- _root.ypos = this._y;
- _root.yspeed = yspeed;
- _root.xspeed = xspeed;
- if(xmove == false)
- {
- if(xspeed < 0)
- {
- xspeed += 0.025;
- }
- if(xspeed > 0)
- {
- xspeed -= 0.025;
- }
- if(_root.increasethrust == false)
- {
- if(xspeed > -0.25 and xspeed < 0.25)
- {
- xspeed = 0;
- }
- }
- }
- xmove = false;
- ymove = false;
- }
-